package cn.com.open.appender;

import com.google.gson.Gson;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import java.util.HashMap;
import java.util.Map;

public class LogTester {

    private static Logger logger = LoggerFactory.getLogger(LogTester.class);

    public static void main(String[] args) {
        Map<String, Object> map = new HashMap<>();
        map.put("userName", "zhangsan");
        map.put("realName", "张三");
        map.put("userAge", "18");
        map.put("userAddress", "北京市海淀区");

        logger.info(new Gson().toJson(map));
    }
}
